class BannerData {
  List<BannerBean>? bannerBean;
  int? errorCode;
  String? errorMsg;

  BannerData({this.bannerBean, this.errorCode, this.errorMsg});

  BannerData.fromJson(Map<String, dynamic> json) {
    if (json['data'] != null) {
      bannerBean =<BannerBean>[];
      json['data'].forEach((v) {
        bannerBean?.add(BannerBean.fromJson(v as Map<String, dynamic>));
      });
    }
    errorCode = json['errorCode'] as int;
    errorMsg = json['errorMsg'] as String;
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = <String, dynamic>{};
    if (bannerBean != null) {
      data['data'] = bannerBean?.map((v) => v.toJson()).toList();
    }
    data['errorCode'] = errorCode;
    data['errorMsg'] = errorMsg;
    return data;
  }
}

class BannerBean {
  String? desc;
  int? id;
  String? imagePath;
  int? isVisible;
  int? order;
  String? title;
  int? type;
  String? url;

  BannerBean(
      {this.desc,
      this.id,
      this.imagePath,
      this.isVisible,
      this.order,
      this.title,
      this.type,
      this.url});

  BannerBean.fromJson(Map<String, dynamic> json) {
    desc = json['desc'] as String;
    id = json['id'] as int;
    imagePath = json['imagePath'] as String;
    isVisible = json['isVisible'] as int;
    order = json['order'] as int;
    title = json['title'] as String;
    type = json['type'] as int;
    url = json['url'] as String;
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['desc'] = this.desc;
    data['id'] = this.id;
    data['imagePath'] = this.imagePath;
    data['isVisible'] = this.isVisible;
    data['order'] = this.order;
    data['title'] = this.title;
    data['type'] = this.type;
    data['url'] = this.url;
    return data;
  }
}
